export default {
  name: "employment",
  components: {
    tab: () => import("../../../component/tab/index.vue"),
    cityCascader: () => import("../../../component/cityCascader/index.vue"),
    check: () => import("../../socical/socialCheck/check.vue"),
    employList: () => import("./employList.vue"),
    clockInList: () => import("./clockInList.vue")
  },
  data() {
    return {
      options: [
		  {table: "4000",tablename: "企业招聘人员管理",totalNum: 0},
		  {table:'4000',tablename: "打卡记录",}
	  ],
      active_type: "0", // 0-企业招聘人员管理  1-打卡记录
	  tol:1
    };
  },
  mounted() {
    let index = this.GLOBAL.permisstions.findIndex(item => item.power === "4");
    this.options = this.GLOBAL.permisstions[index].tablelist;
	console.log(this.options);
	//设置消息气泡的初始值
	this.$set(this.options[0],'totalNum',2);

    this.options.forEach(el => {
      if (el.table == "4000") {
        this.$set(el, "val", "0");
      } else if (el.table == "4001") {
        this.$set(el, "val", "1");
      }
    });
  },
  methods: {
    handleClick(item) {
      this.active_type = item.val;
    }
  }
};
